package com.xiaoyu.lanling.widget.textview

import android.content.Context
import android.util.AttributeSet
import androidx.core.content.ContextCompat
import com.xiaoyu.lanling.R

class RemindDot : androidx.appcompat.widget.AppCompatTextView {

    constructor(context: Context) : this(context, null)
    constructor(context: Context, attrs: AttributeSet?) : super(context, attrs) {
        init()
    }

    private fun init() {
        textSize = 12f
        setTextColor(ContextCompat.getColor(context, R.color.colorOnSecondary))
        minWidth = resources.getDimensionPixelSize(R.dimen.dimension3)
        val horizontalPadding = resources.getDimensionPixelSize(R.dimen.dimension1)
        setPadding(horizontalPadding, 0, horizontalPadding, 0)
        background = ContextCompat.getDrawable(context, R.drawable.msg_count_shape)
    }
}